-- GENERATED SPELL FOR [Bonechewer Backbreaker] --


function spell0_16810(pUnit, Event) --@Bloodlust,n/a--
pUnit:FullCastSpellOnTarget(6742,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16810', 30337, 1)
end

function spell1_16810(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(9613,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16810', 3000, 1)
end

function spell2_16810(pUnit, Event) --@Shadow Shock,n/a--
pUnit:FullCastSpellOnTarget(16583,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16810', 588, 1)
end

function Sorts_16810(pUnit, Event)
local choix_sorts_16810 = math.random(0, 2)
if choix_sorts_16810 == 0 then
pUnit:RegisterEvent('spell0_16810', 1, 1)
end
if choix_sorts_16810 == 1 then
pUnit:RegisterEvent('spell1_16810', 1, 1)
end
if choix_sorts_16810 == 2 then
pUnit:RegisterEvent('spell2_16810', 1, 1)
end
end

function mob16810_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_16810', math.random(1500, 3000), 1)
end

function mob16810_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16810_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16810_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(16810, 1, 'mob16810_Action')
RegisterUnitEvent(16810, 2, 'mob16810_Leave')
RegisterUnitEvent(16810, 3, 'mob16810_Kill')
RegisterUnitEvent(16810, 4, 'mob16810_Die')
